package com.anzia.study_10.data.model;

import ohos.data.orm.OrmObject;
import ohos.data.orm.annotation.Entity;
import ohos.data.orm.annotation.Index;
import ohos.data.orm.annotation.PrimaryKey;

@Entity(tableName = "user",
		ignoredColumns = {"ignore1, ignore2"},
		indices = {@Index(value = {"firstName", "lastName"},
		name = "name_index", unique = true)})
public class User extends OrmObject {
	@PrimaryKey(autoGenerate = true)
	private Integer id;
	private String firstName;
	private String lastName;
	private Integer age;
	private double balance;
	private String ignore1;
	private String ignore2;

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public String getFirstName() {
		return firstName;
	}

	public void setFirstName(String firstName) {
		this.firstName = firstName;
	}

	public String getLastName() {
		return lastName;
	}

	public void setLastName(String lastName) {
		this.lastName = lastName;
	}

	public Integer getAge() {
		return age;
	}

	public void setAge(Integer age) {
		this.age = age;
	}

	public double getBalance() {
		return balance;
	}

	public void setBalance(double balance) {
		this.balance = balance;
	}

	@Override
	public String toString() {
		return super.toString();
	}

	public String getIgnore1() {
		return ignore1;
	}

	public void setIgnore1(String ignore1) {
		this.ignore1 = ignore1;
	}

	public String getIgnore2() {
		return ignore2;
	}

	public void setIgnore2(String ignore2) {
		this.ignore2 = ignore2;
	}
}
